export const useBufferToImgSrc = (arr: number[]): string => {
  if (arr.length > 0) {
    return `data:image/png;base64,${btoa(
      arr.reduce((data, byte) => data + String.fromCharCode(byte), '')
    )}`
  } else return ''
}
